<template>
  <view class="content">
    <view class="status-bar"></view>
    <video-header></video-header>
    <video-list ref="videoList"></video-list>
    <tab></tab>
  </view>
</template>

<script>
  import VideoHeader from "@/components/index/video-header.vue";
  import videoList from "@/components/index/video-list.vue";
  import tab from "@/components/tab.vue";
  export default {
    components: {
      tab,
      VideoHeader,
      videoList,
    },
    data() {
      return {
        title: "我是主页",
        currentVideoId: null,
        comments: [],
        keyboardHeight: 0,
      };
    },
    created() {},
    onShow() {
      // #ifndef MP-WEIXIN
      uni.hideTabBar();
      // #endif
    },
    computed: {
      filteredComments() {
        return this.comments.filter(
          (comment) => comment.video_id === this.currentVideoId
        );
      },
    },
    methods: {},
  };
</script>

<style>
  .content {
    height: 100%;
    width: 100%;
    position: relative; /* 为绝对定位子元素提供参考 */
    overflow: hidden; /* 防止内容溢出 */
  }
</style>
